<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
        <html><head>
        <link rel="stylesheet" type="text/css" href="apidocs.css"/>
        <title>API docs for &ldquo;sympy.core.decimal_math&rdquo;</title>
        </head>
        <body><h1 class="module">Module s.c.decimal_math</h1><span id="part">Part of <a href="sympy.core.html">sympy.core</a></span><div class="toplevel"><div><p>Decimal math functions.</p>
<p>Heavily copied from http://code.google.com/p/dmath/, generalized pow to 
non-integer exponents.</p>
</div></div><table class="children"><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.pi">pi</a></td><td><div><p>Compute Pi to the current precision.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.e">e</a></td><td><div><p>Compute the base of the natural logarithm to the current precision.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.golden_ratio">golden_ratio</a></td><td><div><p>Calculate the golden ratio to the current precision.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.exp">exp</a></td><td><div><p>Return e raised to the power of x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.cos">cos</a></td><td><div><p>Return the cosine of x as measured in radians.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.sin">sin</a></td><td><div><p>Return the sine of x as measured in radians.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.cosh">cosh</a></td><td><div><p>Return the hyperbolic cosine of Decimal x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.sinh">sinh</a></td><td><div><p>Return the hyperbolic sine of Decimal x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.asin">asin</a></td><td><div><p>Return the arc sine (measured in radians) of Decimal x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.acos">acos</a></td><td><div><p>Return the arc cosine (measured in radians) of Decimal x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.tan">tan</a></td><td><div><p>Return the tangent of Decimal x (measured in radians).</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.tanh">tanh</a></td><td><div><p>Return the hyperbolic tangent of Decimal x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.cot">cot</a></td><td><div><p>Return the cotangent of Decimal x (measured in radians).</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.coth">coth</a></td><td><div><p>Return the hyperbolic cotangent of Decimal x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.atan">atan</a></td><td><div><p>Return the arc tangent (measured in radians) of Decimal x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.sign">sign</a></td><td><div><p>Return -1 for negative numbers and 1 for positive numbers.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.atan2">atan2</a></td><td><div><p>Return the arc tangent (measured in radians) of y/x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.log">log</a></td><td><div><p>log(x[, base]) -&gt; the logarithm of Decimal x to the given Decimal 
base.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.log10">log10</a></td><td><div><p>log10(x) -&gt; the base 10 logarithm of Decimal x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.pow">pow</a></td><td><div><p>pow(x,y) -&gt; x ** y.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.degrees">degrees</a></td><td><div><p>degrees(x) -&gt; converts Decimal angle x from radians to degrees</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.radians">radians</a></td><td><div><p>radians(x) -&gt; converts Decimal angle x from degrees to radians</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.ceiling">ceiling</a></td><td><div><p>Return the smallest integral value &gt;= x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.floor">floor</a></td><td><div><p>Return the largest integral value &lt;= x.</p>
</div></td></tr><tr class="function"><td>Function</td><td><a href="#sympy.core.decimal_math.hypot">hypot</a></td><td><div><p>Return the Euclidean distance, sqrt(x*x + y*y).</p>
</div></td></tr></table>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.pi">pi():</a></div>
            <div class="functionBody"><div><p>Compute Pi to the current precision.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.e">e():</a></div>
            <div class="functionBody"><div><p>Compute the base of the natural logarithm to the current precision.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.golden_ratio">golden_ratio():</a></div>
            <div class="functionBody"><div><p>Calculate the golden ratio to the current precision.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.exp">exp(x):</a></div>
            <div class="functionBody"><div><p>Return e raised to the power of x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.cos">cos(x):</a></div>
            <div class="functionBody"><div><p>Return the cosine of x as measured in radians.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.sin">sin(x):</a></div>
            <div class="functionBody"><div><p>Return the sine of x as measured in radians.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.cosh">cosh(x):</a></div>
            <div class="functionBody"><div><p>Return the hyperbolic cosine of Decimal x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.sinh">sinh(x):</a></div>
            <div class="functionBody"><div><p>Return the hyperbolic sine of Decimal x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.asin">asin(x):</a></div>
            <div class="functionBody"><div><p>Return the arc sine (measured in radians) of Decimal x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.acos">acos(x):</a></div>
            <div class="functionBody"><div><p>Return the arc cosine (measured in radians) of Decimal x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.tan">tan(x):</a></div>
            <div class="functionBody"><div><p>Return the tangent of Decimal x (measured in radians).</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.tanh">tanh(x):</a></div>
            <div class="functionBody"><div><p>Return the hyperbolic tangent of Decimal x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.cot">cot(x):</a></div>
            <div class="functionBody"><div><p>Return the cotangent of Decimal x (measured in radians).</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.coth">coth(x):</a></div>
            <div class="functionBody"><div><p>Return the hyperbolic cotangent of Decimal x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.atan">atan(x):</a></div>
            <div class="functionBody"><div><p>Return the arc tangent (measured in radians) of Decimal x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.sign">sign(x):</a></div>
            <div class="functionBody"><div><p>Return -1 for negative numbers and 1 for positive numbers.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.atan2">atan2(y, x):</a></div>
            <div class="functionBody"><div><p>Return the arc tangent (measured in radians) of y/x. Unlike atan(y/x), 
the signs of both x and y are considered.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.log">log(x, base=None):</a></div>
            <div class="functionBody"><div><p>log(x[, base]) -&gt; the logarithm of Decimal x to the given Decimal 
base. If the base not specified, returns the natural logarithm (base e) of 
x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.log10">log10(x):</a></div>
            <div class="functionBody"><div><p>log10(x) -&gt; the base 10 logarithm of Decimal x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.pow">pow(x, y):</a></div>
            <div class="functionBody"><div><p>pow(x,y) -&gt; x ** y.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.degrees">degrees(x):</a></div>
            <div class="functionBody"><div><p>degrees(x) -&gt; converts Decimal angle x from radians to degrees</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.radians">radians(x):</a></div>
            <div class="functionBody"><div><p>radians(x) -&gt; converts Decimal angle x from degrees to radians</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.ceiling">ceiling(x):</a></div>
            <div class="functionBody"><div><p>Return the smallest integral value &gt;= x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.floor">floor(x):</a></div>
            <div class="functionBody"><div><p>Return the largest integral value &lt;= x.</p>
</div></div>
            </div>
            <div class="function">
            <div class="functionHeader">def <a name="sympy.core.decimal_math.hypot">hypot(x, y):</a></div>
            <div class="functionBody"><div><p>Return the Euclidean distance, sqrt(x*x + y*y).</p>
</div></div>
            </div></body>
        